using System;

namespace MiniStock.BusinessLogic.EventProcessor.EntityCache
{
    public class LockObject {
        public object Item { get; private set; }
        public LockObject(object item)
        {
            if(item is LockObject)
                throw new InvalidOperationException("Cannot lock a locked item");

            if(item == null)
                throw new ArgumentNullException("item");

            Item = item; 
        } 
    }
}